package com.wicket.okrapp.web.contorller;

import com.wicket.okrapp.biz.service.ExecuteCycleService;
import com.wicket.okrapp.biz.service.dto.req.*;
import com.wicket.okrapp.biz.service.dto.res.*;
import com.wicket.okrapp.common.ro.OkrResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author ：
 * @date ：
 *
 *
 * @version 1.0
 */
@RestController
@RequestMapping("/app/executeCycle/")
public class ExecuteCycleController {

  @Autowired
  ExecuteCycleService executeCycleService;
/**
   * D3-执行周期回写目标周期ID(公共)
   */
    @PostMapping("implementExecuteCycleWriteBackEvaObjectCycleIdCom")
    public OkrResult<ImplementExecuteCycleWriteBackEvaObjectCycleIdComRespDto> implementExecuteCycleWriteBackEvaObjectCycleIdCom(@RequestBody @Validated ImplementExecuteCycleWriteBackEvaObjectCycleIdComReqDto reqDTO){
    return OkrResult.success(executeCycleService.implementExecuteCycleWriteBackEvaObjectCycleIdCom(reqDTO));
    }
/**
   * D3-查询执行周期详情（开始小于等于&结束大于等于）(公共)
   */
    @PostMapping("queryExecuteCycleLessStartBIgEndDetailCom")
    public OkrResult<QueryExecuteCycleLessStartBIgEndDetailComRespDto> queryExecuteCycleLessStartBIgEndDetailCom(@RequestBody @Validated QueryExecuteCycleLessStartBIgEndDetailComReqDto reqDTO){
    return OkrResult.success(executeCycleService.queryExecuteCycleLessStartBIgEndDetailCom(reqDTO));
    }
/**
   * D3-执行更新周期时间切片分析(公共)
   */
    @PostMapping("implementUpdateCycleTimeSliceAnalyzeCom")
    public OkrResult<ImplementUpdateCycleTimeSliceAnalyzeComRespDto> implementUpdateCycleTimeSliceAnalyzeCom(@RequestBody @Validated ImplementUpdateCycleTimeSliceAnalyzeComReqDto reqDTO){
    return OkrResult.success(executeCycleService.implementUpdateCycleTimeSliceAnalyzeCom(reqDTO));
    }
/**
   * D3-执行相同周期类型当前及历史周期(公共)
   */
    @PostMapping("implementCurrentAndHistoryCycleOfSameCycleTypeCom")
    public OkrResult<ImplementCurrentAndHistoryCycleOfSameCycleTypeComRespDto> implementCurrentAndHistoryCycleOfSameCycleTypeCom(@RequestBody @Validated ImplementCurrentAndHistoryCycleOfSameCycleTypeComReqDto reqDTO){
    return OkrResult.success(executeCycleService.implementCurrentAndHistoryCycleOfSameCycleTypeCom(reqDTO));
    }
/**
   * D3-查询最近可循环最大执行周期详情(公共)
   */
    @PostMapping("queryNextCycleMaxPeriodDetailCom")
    public OkrResult<QueryNextCycleMaxPeriodDetailComRespDto> queryNextCycleMaxPeriodDetailCom(@RequestBody @Validated QueryNextCycleMaxPeriodDetailComReqDto reqDTO){
    return OkrResult.success(executeCycleService.queryNextCycleMaxPeriodDetailCom(reqDTO));
    }
/**
   * D3获取当前目标内容执行周期(公共)
   */
    @PostMapping("obtainCurrentTargetContexeCuteCycleCom")
    public OkrResult<ObtainCurrentTargetContexeCuteCycleComRespDto> obtainCurrentTargetContexeCuteCycleCom(@RequestBody @Validated ObtainCurrentTargetContexeCuteCycleComReqDto reqDTO){
    return OkrResult.success(executeCycleService.obtainCurrentTargetContexeCuteCycleCom(reqDTO));
    }
/**
   * D3-查询上一个执行周期的周期及目标周期详情(公共)
   */
    @PostMapping("queryLastExecCycleAndTargetCycleDetailCom")
    public OkrResult<QueryLastExecCycleAndTargetCycleDetailComRespDto> queryLastExecCycleAndTargetCycleDetailCom(@RequestBody @Validated QueryLastExecCycleAndTargetCycleDetailComReqDto reqDTO){
    return OkrResult.success(executeCycleService.queryLastExecCycleAndTargetCycleDetailCom(reqDTO));
    }
/**
   * D3执行过往执行周期是否末级处理(公共)
   */
    @PostMapping("implementWhetherPastExecutionPeriodIsLastDisposeCom")
    public OkrResult<ImplementWhetherPastExecutionPeriodIsLastDisposeComRespDto> implementWhetherPastExecutionPeriodIsLastDisposeCom(@RequestBody @Validated ImplementWhetherPastExecutionPeriodIsLastDisposeComReqDto reqDTO){
    return OkrResult.success(executeCycleService.implementWhetherPastExecutionPeriodIsLastDisposeCom(reqDTO));
    }
/**
   * D3分析上一个执行周期的周期及目标周期(公共)
   */
    @PostMapping("analysisLastExecCycleAndTargetCycleCom")
    public OkrResult<AnalysisLastExecCycleAndTargetCycleComRespDto> analysisLastExecCycleAndTargetCycleCom(@RequestBody @Validated AnalysisLastExecCycleAndTargetCycleComReqDto reqDTO){
    return OkrResult.success(executeCycleService.analysisLastExecCycleAndTargetCycleCom(reqDTO));
    }
/**
   * D3执行周期查询条件分析(公共)
   */
    @PostMapping("implementExecuteCycleConditionsCom")
    public OkrResult<ImplementExecuteCycleConditionsComRespDto> implementExecuteCycleConditionsCom(@RequestBody @Validated ImplementExecuteCycleConditionsComReqDto reqDTO){
    return OkrResult.success(executeCycleService.implementExecuteCycleConditionsCom(reqDTO));
    }
/**
   * D3查询目标内容执行周期详情(公共)
   */
    @PostMapping("queryTargetContexeCuteCycleDetailCom")
    public OkrResult<QueryTargetContexeCuteCycleDetailComRespDto> queryTargetContexeCuteCycleDetailCom(@RequestBody @Validated QueryTargetContexeCuteCycleDetailComReqDto reqDTO){
    return OkrResult.success(executeCycleService.queryTargetContexeCuteCycleDetailCom(reqDTO));
    }
/**
   * D3查询执行周期阶段（时间从小到大）列表(公共)
   */
    @PostMapping("queryExecuteCycleByTimeBigtoSmallListCom")
    public OkrResult<QueryExecuteCycleByTimeBigtoSmallListComRespDto> queryExecuteCycleByTimeBigtoSmallListCom(@RequestBody @Validated QueryExecuteCycleByTimeBigtoSmallListComReqDto reqDTO){
    return OkrResult.success(executeCycleService.queryExecuteCycleByTimeBigtoSmallListCom(reqDTO));
    }
/**
   * D3查工作周期范围内执行周期详情（开始大于等于&结束小于等于）
   */
    @PostMapping("queryExecuteCycleBigStartLessEndDetailCom")
    public OkrResult<QueryExecuteCycleBigStartLessEndDetailComRespDto> queryExecuteCycleBigStartLessEndDetailCom(@RequestBody @Validated QueryExecuteCycleBigStartLessEndDetailComReqDto reqDTO){
    return OkrResult.success(executeCycleService.queryExecuteCycleBigStartLessEndDetailCom(reqDTO));
    }
/**
   * D3查询执行周期阶段列表（开始大于等于&结束小于等于）
   */
    @PostMapping("queryExecuteCycleBigStartLessEndListCom")
    public OkrResult<QueryExecuteCycleBigStartLessEndListComRespDto> queryExecuteCycleBigStartLessEndListCom(@RequestBody @Validated QueryExecuteCycleBigStartLessEndListComReqDto reqDTO){
    return OkrResult.success(executeCycleService.queryExecuteCycleBigStartLessEndListCom(reqDTO));
    }
/**
   * D3查询执行周期阶段列表（开始小于等于&结束大于等于）
   */
    @PostMapping("queryExecuteCycleLessStartBIgEndListCom")
    public OkrResult<QueryExecuteCycleLessStartBIgEndListComRespDto> queryExecuteCycleLessStartBIgEndListCom(@RequestBody @Validated QueryExecuteCycleLessStartBIgEndListComReqDto reqDTO){
    return OkrResult.success(executeCycleService.queryExecuteCycleLessStartBIgEndListCom(reqDTO));
    }
/**
   * D3查询执行周期阶段列表(公共)
   */
    @PostMapping("queryExecuteCycleByEvaTempListCom")
    public OkrResult<QueryExecuteCycleByEvaTempListComRespDto> queryExecuteCycleByEvaTempListCom(@RequestBody @Validated QueryExecuteCycleByEvaTempListComReqDto reqDTO){
    return OkrResult.success(executeCycleService.queryExecuteCycleByEvaTempListCom(reqDTO));
    }
/**
   * D3批量查询执行周期阶段列表ByIds(公共)
   */
    @PostMapping("batchQueryExecuteCycleByEvaTempListByIdsCom")
    public OkrResult<BatchQueryExecuteCycleByEvaTempListByIdsComRespDto> batchQueryExecuteCycleByEvaTempListByIdsCom(@RequestBody @Validated BatchQueryExecuteCycleByEvaTempListByIdsComReqDto reqDTO){
    return OkrResult.success(executeCycleService.batchQueryExecuteCycleByEvaTempListByIdsCom(reqDTO));
    }
/**
   * D3批量查询执行周期阶段By内容ID列表(公共)
   */
    @PostMapping("batchQueryExecuteCycleByContIdListByIdsCom")
    public OkrResult<BatchQueryExecuteCycleByContIdListByIdsComRespDto> batchQueryExecuteCycleByContIdListByIdsCom(@RequestBody @Validated BatchQueryExecuteCycleByContIdListByIdsComReqDto reqDTO){
    return OkrResult.success(executeCycleService.batchQueryExecuteCycleByContIdListByIdsCom(reqDTO));
    }
/**
   * D3查询上一个执行周期的周期详情(公共)
   */
    @PostMapping("queryLastExecCycleDetailCom")
    public OkrResult<QueryLastExecCycleDetailComRespDto> queryLastExecCycleDetailCom(@RequestBody @Validated QueryLastExecCycleDetailComReqDto reqDTO){
    return OkrResult.success(executeCycleService.queryLastExecCycleDetailCom(reqDTO));
    }
}
